\documentclass[11pt,twoside]{article}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%
% Begin Document Header Here
%
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%------------page layout
\usepackage[left=2.5cm,top=3cm,right=2.5cm,bottom=2cm]{geometry} %changes margins
\usepackage[parfill]{parskip} % begin paragraphs with an empty line not indent
\usepackage{multicol,setspace}

%%------------symbols and equations
\usepackage{amsmath}


%%-----------section styles
\usepackage{sectsty}
    %Put period after section number
\makeatletter
\def\@seccntformat#1{\@ifundefined{#1@cntformat}%
{\csname the#1\endcsname\quad}% default
{\csname #1@cntformat\endcsname}% individual control
}
\def\section@cntformat{\thesection.\quad}
\def\subsection@cntformat{\thesubsection.\quad}
\makeatother
\sectionfont{\bf\large\raggedright}
\subsectionfont{\bf\normalsize\raggedright}
\subsubsectionfont{\bf}


%%------------font choices
%\usepackage[scaled=.9]{couriers}
%\usepackage{pxfonts}
%\usepackage{mathpazo}
%\usepackage{mathpple}
%\usepackage{fouriernc}
%\usepackage[garamond]{mathdesign}
%\usepackage{kurier}
\usepackage{palatino}


%%------------graphics
\usepackage{graphicx,epstopdf}
\usepackage{wrapfig}
\usepackage{subfigure}


%%------------bibliography
\usepackage{natbib}
\bibliographystyle{agufull04}

%%------------tables
\usepackage{booktabs}

%%------------misc
\usepackage{verbatim}
\usepackage[pdftex,bookmarks,colorlinks,breaklinks]{hyperref}
\hypersetup{linkcolor=black,citecolor=black,filecolor=black,urlcolor=black}
\usepackage[all]{hypcap}
\usepackage{varioref}


%%-----------custom environments
%%enumerate and itemize with smaller spacing
\newenvironment{myen}{
\begin{enumerate}
  \setlength{\itemsep}{1pt}
  \setlength{\parskip}{0pt}
  \setlength{\parsep}{0pt}}{\end{enumerate}
}
\newenvironment{myit}{
\begin{itemize}
  \setlength{\itemsep}{1pt}
  \setlength{\parskip}{0pt}
  \setlength{\parsep}{0pt}}{\end{itemize}
}

\renewcommand{\[ }{\begin{equation}}
\renewcommand{\] }{\end{equation}}

%%------------page header declaration
\newcommand{\Ohead}{Capstone Engineering: Fall 2008}                %header for Odd pages
\newcommand{\Ehead}{\textit{Arcata Brackish Marsh}}  %header for Even pages
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhead{}
\fancyfoot{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
\fancyhead[CE]{\small \Ehead}{}
\fancyhead[CO]{\small \Ohead}{}
\fancyhead[LE,RO]{\thepage}   %page numbers

%%-----------nicer looking captions
\usepackage[font={bf,footnotesize},textfont=md,margin=30pt,aboveskip=0pt,belowskip=0pt]{caption}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%
% End Document Header Here
%
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%
% Document Starts Here
%
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}

\thispagestyle{empty}

~\vspace{5.5cm}
\begin{center}
    \textbf{\Large Integration of the McDaniel Slough Brackish Marsh into the Arcata \\ Wastewater Treatment Facility\\}
    \vspace{1cm}
    { Neil Berezovsky, Cameron Bracken, Amelia Dillon EIT, }\\{Jordan Pierce EIT, and Jason M. Roberts}\\
    \vspace{1cm}
    {\it Capstone Engineering, Fall 2008}\\
    {\it Humboldt State University, Arcata CA}\\
\end{center}
\clearpage

\thispagestyle{empty}

\begin{center}
    \textbf{\large Integration of the McDaniel Slough Brackish Marsh into the Arcata Wastewater Treatment Facility\\}
    \vspace{.4cm}
    {\ Neil Berezovsky, Cameron Bracken, Amelia Dillon EIT, \\ Jordan Pierce EIT, and Jason M. Roberts}\\
    \vspace{.4cm}
    {\it Capstone Engineering: Fall 2008 \\ Humboldt State University, Arcata
    CA}\\
    \vspace{.8cm}
    {\bf Executive Summary}\\
\end{center}

The City of Arcata has requested a hydraulic analysis of the Arcata
Wastewater Treatment Facility (AWTF) to address limitations of the
current system and to suggest possible improvements. Further, recent
development of a tidally influenced brackish marsh adjacent to
AWTF's treatment wetlands has given rise to the possibility of
integrating the new marsh into the treatment system. Additional
stakeholders in the decision making process are the California
Department of Fish and Game and the North Coast Regional Water
Quality Control Board.

This paper outlines (1) the existing conditions and proposed changes
to the AWTF treatment wetlands, (2) a review of relevant literature
on the development of a hydraulic model, inflow forecasting, and
modeling hydraulic control structures, (3) the application and
results of the AWTF hydraulic model, (4) a discussion and analysis
of the possibility of integrating the Brackish Marsh in series with
the existing treatment wetlands, and (5) the development of a
web-based model interface to be utilized by the AWTF operators.

The hydraulic model assumes each wetland behaves as a
linear-reservoir, where the stage-discharge relationship is governed
by equations of flow through weirs, sluices, and/or pipes. The model
was calibrated and verified with historical data and daily plant
records. AWTF inflow depends strongly upon precipitation; therefore,
an inflow forecasting model was developed based upon precipitation
predictions. Historical inflow records from the treatment facility
(1988--present) were correlated with historical precipitation
records using the Season Trend Loess (STL) algorithm.

Results indicate that integration of the Brackish Marsh in series
with the existing treatment wetlands is feasible given minor system
modifications. Further study is required to assess whether specific
integration scenarios meet water quality constraints. Daily
forecasted water surface elevations are accurate to within 1-2
inches, and forecasted wastewater discharges to within 1 mgd. The
web-based interface can be utilized to adjust model parameters to
reflect changes in the physical system, e.g., weir heights and
pumping schedules. To improve upon the hydraulic model,
recommendations are presented for more accurate measurements of
system components.

\clearpage
\pagenumbering{roman}
\tableofcontents
\newpage
\listoffigures
\listoftables

\clearpage

\pagenumbering{arabic}
\setcounter{page}{1}


\section{Introduction}\label{sec:intro}

The City of Arcata Wastewater Treatment Facility (AWTF) utilizes a
traditional primary treatment system combined with progressive
natural processes for secondary and tertiary treatment. Although the
combination of the primary treatment system with oxidation ponds,
treatment marshes, and enhancement marshes has performed well for
more than 30 years, the facility has recently been fined for failing to meet permitting standards
designed for more traditional systems. In an effort to reduce
discharge permit violations, the City of Arcata is interested in
utilizing a newly constructed Brackish Marsh for increased treatment
capacity. The Brackish Marsh is part of the larger McDaniel Slough
restoration project focused on the creation of diverse habitat for
aquatic species and waterfowl. Freshwater inflow from the treatment
plant and saltwater flow from Humboldt Bay will mix to create
brackish conditions in the marsh. The City of Arcata has requested
that the HSU Capstone Engineering Team investigate the hydraulic
feasibility of integrating the Brackish Marsh into the existing
wastewater treatment process. The objectives of this project are
(1) to produce an operational tool to forecast and manage
conditions in the existing treatment system on a daily basis, (2) to develop a simple and intuitive user interface to this model and (3)
investigate the hydraulic feasibility of connecting the Brackish Marsh
in series with the existing treatment system while maintaining a single
point of discharge.

\begin{figure}[!hb]
\centering
\includegraphics[width=\textwidth]{figs/restoration-withborder.pdf}
\caption{The location of Arcata, CA and the AWTF.}\label{fig:site-maps}
\end{figure}


A numerical flow model was developed to simulate the flow of
water through the system and to assess treatment capacity in
terms of storage volume. Calibration and verification of the
numerical model was performed using historical data. The
calibrated flow model was used to investigate the hydraulic
behavior of the Brackish Marsh and treatment system.

In addition to the feasibility study, an operational tool was
developed to predict water levels throughout the treatment system.
The tool will enable plant operators to identify and respond to
potential problems associated with high flow events, and allow for
testing of routing scenarios without physical manipulation of the
system. Predicted data, rather than historical data, is used to
drive the simulation model for forecasting purposes. The tool
utilizes a precipitation driven inflow model, predicted tidal
elevations, and the physical and hydraulic constraints of the
system to forecast water levels on a daily basis. A web based
interface allows for remote use by treatment plant operators.

This paper outlines:
(1) the existing conditions and proposed changes to the marsh
system, (2) a review of relevant literature for hydraulic model
development, inflow forecasting, and tide gate modeling, (3)
application and results of the simulation model, and (4) a
discussion and analysis of the possibility of integrating the
Brackish Marsh in series with the existing treatment wetlands.

\section{Project Background}\label{sec:back}

\subsection{History}
The site of the AWTF has seen many uses prior to its current state.
Historically the area was brackish wetlands, which were home to diverse
waterfowl, wildlife, and aquatic species, and were also utilized by local
Indian tribes. Development of Humboldt County during the timber boom
resulted in the diking and filling of the wetlands for use as a
landfill. In 1933, Arcata's wastewater collection system discharged
untreated effluent through a 400 ft. pipe emptying into a 500 ft.
ditch just East of Butcher's Slough. The poor effluent quality
contaminated oyster beds in Humboldt Bay, bringing attention to the
environmental and economic problem. In the 1940s, a treatment plant
was built providing only primary treatment of wastewater. In 1958,
55 acres of oxidation ponds were added, followed by chlorination and
dechlorination in 1968 and 1975, respectively
\citep{EcoTippingPoints2008}.

The North Coast Regional Water Quality Control Board's (NCRWQCB)
Basin Plan of 1975 increased wastewater discharge standards into
bays, putting a financial strain on small communities such as
Arcata, McKinleyville, and Eureka. As a result of the Basin Plan, the
construction of a regional wastewater treatment plant
 on the Samoa Peninsula was proposed, with waste to be discharged into the Pacific Ocean. The combined funds of the three cities were deemed adequate to construct a facility that would meet
increased discharge standards as set forth by the Basin Plan
\citep{EcoTippingPoints2008}. In 1979, the City of Arcata chose not
to participate in the regional wastewater treatment plant in favor
of developing a pilot treatment marsh project
\citep{EcoTippingPoints2008}.

\subsection{Current Profile}
The current AWTF, built in 1984, was designed to treat 2.3 mgd, which was the
average municipal waste water flow of the design year of 1992
\citep{CH2MHill}. The treatment facility consists of primary,
secondary and tertiary treatment followed by disinfection
\citep{CH2MHill}. Primary treatment includes the plant headworks, a
clarifier, two anaerobic digesters, and sludge drying beds.
Secondary treatment is comprised of 45 acres of oxidation ponds (Ox
Ponds) and 5 acres of treatment marshes (TMs). Tertiary treatment is
provided by 28 acres of enhancement marshes (EMs) that comprise a
portion of the Arcata Marsh \& Wildlife Sanctuary (AMWS).
Chlorination and dechlorination are performed prior to discharge
into Humboldt Bay, and prior to flow through the EMs. The
constructed wetland treatment system (Figure \vref{fig:scale-marsh})
has since gained international recognition as an alternative to
conventional treatment.

\begin{figure}[!ht]
\centering
\includegraphics[width=\textwidth]{figs/aerial.pdf}
\caption{Diagram of the Arcata Wastewater Treatment
Wetlands.}\label{fig:scale-marsh}
\end{figure}


The AWTF utilizes a conventional primary treatment train. The
headworks removes large floating debris with mechanically cleaned
bar racks, removes grit with a horizontal flow grit chamber, and
elevates the water to allow gravity-driven movement through the
treatment system via two Archimedes screw pumps \citep{CH2MHill}.
Immediately following the headworks is a clarifier which allows for
the settling of suspended solids.  The settled sludge from the
clarifier is sent through two anaerobic digesters connected in
series. The digesters provide substrate for anaerobic bacteria that
decompose sludge. Processed sludge is extracted from the digesters
and sent to drying beds for compost preparation and eventual use as
fertilizer on city parks.

The clarifier supernatant is collected and sent through secondary
treatment: a collection of three in-series Ox Ponds connected to
four TMs in parallel. The Ox Ponds reduce biochemical oxygen demand
(BOD) through bacterial oxidation, remove total suspended solids
(TSS) through sedimentation, and remove organic nutrients through
bacterial fixation and sedimentation \citep{Finney2008}. Following
the Ox Ponds, wastewater moves through the TMs which contain dense
plant matter that effectively act as large filtration systems. The
TMs provide additional settling of suspended solids, block sunlight
to inhibit algae growth, bind phosphorus to plant matter, and
provide large surface areas for beneficial bacterial habitat. The
flow of water through the Ox Ponds and TMs is shown in figure
\ref{fig:pond-tm-connections}.

\begin{figure}[!ht]
\centering
\includegraphics[width=\textwidth]{figs/connections-all.pdf}
\caption{Simplified flow diagram of the Oxidation Ponds and
Treatment Marshes.} \label{fig:pond-tm-connections}
\end{figure}


When storm events increase plant inflows during winter months,
emergency pumps move water through the system at a higher rate,
potentially by-passing components of the treatment system. A total
of ten pumps are capable of moving water through the Ox Ponds and
TMs to the Chlorine Contact Basin: 3 pumps can move water from the
TM collection system, 3 pumps can move water from the Ox Pond
collection system, 2 pumps can move water directly from Ox Pond 3,
and 2 pumps can move water directly from Ox Pond 2. When wastewater
is pumped directly from Ox Pond 2 or 3, it bypasses the TMs and
receives less treatment. In these situations, constituent
concentrations are highly diluted by the addition of rain water, but
overall mass loading has the potential to exceed permit standards.
In response to increased inflows, AWTF operators engage additional
pumps as outlined in Table \vref{tab:pumping}, with corresponding
combined pump capacities.

\begin{table}[!htbp]
   \centering
   \caption{Incremental pumping capacity based on various pumping scenarios.}
   \begin{tabular}{@{} ccccc @{}}
      \toprule
      \multicolumn{2}{@{} l}{Daily Operational Pumps}&
      \multicolumn{2}{c @{}}{Emergency Pumps} &\\
      \cmidrule(r){1-4}
      TM & Ox Pond & Ox Pond 3 & Ox Pond 2 & Total Capacity (mgd) \\
      \midrule
      2 & 1 & - & - & 4.5 \\
      3 & 1 & - & - & 4.9 \\
      3 & 3 & - & - & 6.0 \\
      3 & 3 & 1 & - & 7.5 \\
      3 & 3 & 2 & - & 8.4 \\
      3 & 3 & 2 & 1 & 11.9 \\
      3 & 3 & 2 & 2 & 13.6 \\
      \bottomrule
   \end{tabular}\label{tab:pumping}
\end{table}

After secondary treatment, water is collected and pumped to the
Chlorine Contact Basin for disinfection. Disinfected effluent is
discharged to two locations: Outfall No.\ 001 at Butcher's Slough,
and Outfall No.\ 002 at Allen Marsh, the first of the EMs. The three
in-series EMs; Allen, Gearheart, and Hauser, work both as oxidation
ponds and treatment marshes, as they contain a combination of open
water and dense vegetation. After flowing through the EMs, effluent
is pumped back to the Chlorine Contact Basin at a point halfway
through the disinfection process. The EMs and the AMWS are an
integral part of the system as they provide high level treatment
while providing diverse wildlife habitat and an area for recreation
and education.


\subsection{Regulations and Permits}

The quality of water discharged by the AWTF is regulated by federal,
state, and regional legislation. The Federal Clean Water Act
protects navigable waters, and the California Water Code regulates
discharges to groundwater and surface waters.


\subsubsection{Federal Regulations}

In 1972, the U.S. Environmental Protection Agency (EPA) established
the Clean Water Act (CWA), an expansion on the 1948 Federal Water
Pollution Control Act. The CWA allows the EPA to regulate pollutant
discharges into U.S. waters and establish surface water quality standards.
Through the CWA, the EPA introduced the National Pollutant Discharge
Elimination System (NPDES) which requires permits for any point
source pollutant discharge, including wastewater, into designated water bodies
\citep{EPA2008a}. Under NPDES guidelines, wastewater effluent cannot
be discharged into bays or estuaries unless it enhances the overall quality
of the receiving body \citep{EcoTippingPoints2008}.

\subsubsection{State Regulations}

Under the CWA, states are authorized to develop area-wide wastewater
management plans. In California, the protection and enhancement of
water quality is determined by the State Water Resources Control
Board (SWB) and nine regional water quality control
boards. The SWB establishes statewide policies and
laws to ensure high quality standards in California. The nine
regional water boards create water quality control plans (basin
plans) to emphasize the uniqueness of the nature, beneficial uses,
and problems of each region \citep{NCRWQCB2007}.

The SWB and the nine regional water boards were established in 1969
under the Porter-Cologne Water Quality Control Act, an expansion of
the 1949 Dickey Act. In 1971 the NCRWQCB developed an interim Basin
Plan which was developed into comprehensive basin plans for the
Klamath River Basin and the North Coastal Basin in 1975. The Basin
Plan phased out discharges into bays, though exceptions were granted
to wastewater discharges that enhance the quality of the receiving
waters to a point greater than if there were no discharge
\citep{EcoTippingPoints2008}. The AWTF was granted this exception.
In 1988 the Water Quality Control Plan for the North Coast Region
(Basin Plan) was developed as an amendment to the 1975 plans. The
Basin Plan is mainly a regulatory tool to preserve and enhance water
quality while protecting beneficial uses of water in the North Coast
Region. The water quality objectives outlined in the Basin Plan
provide the basis for wastewater discharge standards. Wastewater
discharge permits are granted according to the following guidelines:


\begin{myit}
\item That the waste is treated to the highest practical level,
\item That the discharge will not lower water quality below prescribed state standards, following the CWA,
\item That public health and welfare are protected, and
\item That the maximum benefit to the people of the state is maintained.
\end{myit}

The Regional Water Board recognizes that compliance may not be
technically and/or economically feasible under all circumstances.

\subsubsection{Current Discharge Permit}

The current wastewater discharge permit for the City of Arcata
(NPDES Permit No. CA0022713) was granted in June 2004 and expires
June 2009. The permit allows two discharge points; Outfall No. 001
into Butcher's Slough, and Outfall No. 002 into the EMs, part of the
AMWS \citep{CRWQCB2004,EPA2008}.

The NPDES permit prohibits discharge of waste into Humboldt Bay that
is not specifically regulated by the permit, that is not in
conjunction with the AMWS, and that is untreated or partially
treated from any point in the treatment or collection system. Tables
\ref{tab:001} and \vref{tab:002} outline the constituent limits for
discharge at Outfalls No. 001 and No. 002, respectively. Also
included in the permit are constituent limitations placed upon the
receiving waters.

\begin{table}[!htbp]
   \centering
   \caption{Discharge limitations at Outfall No. 001 \citep{CRWQCB2004}.}\label{tab:001}
   \begin{tabular}{@{} ccccc @{}}
      \toprule
        & Units & Monthly Average & Weekly Average & Daily Maximum \\
      \midrule
      BOD$_5$           & mg/L      & 30                  & 45 & 60   \\
      Suspended Solids  & mg/L      & 30                  & 45 & 60   \\
      Settleable Solids & mL/L      & 0.1                 & -  & 0.2  \\
      Fecal Coliform    & MPN/100mL & 14                  & -  & 43   \\
      pH                & Standard  & $>$ 6.0 and $<$ 9.0 &    &      \\
      Copper            & $\mu$g/L  & 2.8                 & -  & 5.7  \\
      Zinc              & $\mu$g/L  & 47                  & -  & 95   \\
      Cyanide           & $\mu$g/L  & 0.5                 & -  & 1.0  \\
      2,3,7,8-TCDD TEQ  & pg/L      & 0.014               & -  & 0.028\\
      \bottomrule
   \end{tabular}
\end{table}

\begin{table}[!htbp]
   \centering
   \caption{Discharge limitations at Outfall No. 002 \citep{CRWQCB2004}.}\label{tab:002}
   \begin{tabular}{@{} ccccc @{}}
      \toprule
        & Units & Monthly Average & Weekly Average & Daily Maximum \\
      \midrule
      BOD$_5$           & mg/L      & 30                  & 45 & 60   \\
      Suspended Solids  & mg/L      & 30                  & 45 & 60   \\
      Settleable Solids & mL/L      & 0.1                 & -  & 0.2  \\
      Fecal Coliform    & MPN/100mL & 23                  & -  & 230   \\
      pH                & Standard  & $>$ 6.0 and $<$ 9.0 &    &      \\
      \bottomrule
   \end{tabular}
\end{table}


\subsubsection{Permit Violations}

As outlined in \cite{NCRWQCB2007}, the City of Arcata's NPDES permit
requires issuance of monthly and annual NPDES self-monitoring
reports to the NCRWQCB. Violations occur when the discharge exceeds
limitations by 40\% or more for a Group I pollutant or by 20\% or
more for a Group II pollutant. In the case of the City of Arcata,
BOD and TSS are the main Group I pollutants and cyanide and copper
are the main Group II pollutants. Though fecal coliforms do not fall
under either category, exceedances are counted, but not as serious
violations. If a violation occurs, the following penalties apply:


\begin{myit}
\item A maximum fine of \$10,000 for each day a violation occurs plus up to \$10 per gallon of waste discharged in excess of 1,000 gallons (for waste not cleaned up);
\item A mandatory minimum penalty (MMP) of \$3,000 for each serious violation of the NPDES effluent limitation.
\end{myit}

In 1998, NPDES permit No. CA0022713 was issued to the Arcata
Wastewater Treatment Facility for Outfall No. 001 and Outfall No.
002, which expired in 2004. From January 2000 to June 2004, 114
violations of effluent limits occurred for a penalty of \$306,000.
In June 2004, the City of Arcata was granted a second wastewater
discharge permit (NPDES permit No. CA0022713) for Outfall No. 001
and Outfall No. 002, which expires June 2009. In June 2006, the City
of Arcata adopted the Statewide General Waste Discharge Requirements
(General WDRs) for Wastewater Collection Agencies. Between June 2004
and March 2007, the effluent limitations were exceeded 21 times for
a MMP of \$54,000, and 17 sanitary sewer overflows (SSOs) were
reported for a maximum penalty of \$216,600 \citep{CRWQCB2007}. Of
the MMPs, \$33,000 was related to violations of BOD, TSS, Percent
Removal, and Coliform Bacteria. In February 2008, the City of Arcata
filed a lawsuit to vacate the MMPs and modify certain provisions of
the current NPDES discharge permit \citep{CRWQCB2007}. The CRWQCB
has agreed not to charge the City of Arcata for the MMPs until the
lawsuit is settled \citep{CRWQCB2008}. None of the wastewater from
SSO events was captured or cleaned up, and all discharges were
determined to pose a threat to public health and have detrimental
impacts on the beneficial uses of the receiving waters. The nature
of the SSOs resulted in a penalty of \$50,000 and a mandate to
repair the problematic locations of the collection system
\citep{CRWQCB2007}.


\section{Anticipated Changes}\label{sec:changes}

\subsection{The Brackish Marsh}
The City of Arcata, in conjunction with the Department of Fish and
Game and a number of other federal, state, and local agencies,
recently began the restoration of McDaniel Slough, located directly
to the northwest of the AWTF. A 35 acre portion of the restoration
area, bordering the EMs, has been designated as a Brackish Marsh.
The marsh is to be fed by an upstream freshwater supply, and salt
water supplied by Humboldt Bay through a muted tide gate. The
location of the Brackish Marsh, the need for a freshwater supply,
and the AWTF's need for increased treatment capacity prompted the
City of Arcata to consider using treated wastewater effluent as the
freshwater source. Currently, there are a number of scenarios for
integrating the Brackish Marsh into the AWTF system given physical
constraints of the system and possible permitting options. The
Brackish Marsh was designed to receive from 1 to 6 cfs of
freshwater, a combination of direct influent and surface runoff from
a neighboring 20 acres of upland area, and salt water, as influenced
by the tides of Humboldt Bay \citep{CDFG2006}.


\subsubsection{Vision for the Brackish Marsh}
Because there are multiple stakeholders in the McDaniel Slough
restoration project (NCRWQB, Department of Fish and Game, and the
City of Arcata), there are many objectives associated with
integration of the Brackish Marsh.

The Department of Fish and Game views the Brackish Marsh as an
extension of the estuarine conditions of McDaniel Slough, providing
waterfowl, wildlife and aquatic habitat. From the standpoint of the
City of Arcata and AWTF operators, the Brackish Marsh presents an
opportunity to expand the treatment capacity of the existing
facility, thereby mitigating future violations of the discharge
permit \citep{CDFG2006}.

\subsubsection{Scenarios for Integration}

Likely scenarios for integrating the brackish marsh with the
existing wetlands are shown in Figures \ref{fig:tm-current} through
\ref{fig:tm-none}. Selection of the best alternative depends largely
on the location and constraints of the discharge permit currently
under negotiation \citep{Andre2008}. The North Coast Regional Water
Quality Board (NCRWQB) wishes to designate the enhancement marshes
as ``waters of the United States,'' thereby removing them from the
treatment system \citep{Andre2008}. Such a decision would: (1)
decrease the capacity of the treatment facility to buffer high
flows, and (2) increase the potential for mass- and
concentration-violations of the discharge permit. From the
standpoint of the City of Arcata, the most favorable location of the
discharge point would be downstream of the brackish marsh, i.e., at
the tide gate. The hydraulic regimes shown in Figures
\ref{fig:tm-all-series} through \ref{fig:tm-none} represent varying
levels of compromise between the City and Regional Board.

The existing regime is shown in Figure \ref{fig:tm-current}, where
effluent from Hauser returns to the Chlorine Contact Basin prior to
final discharge. The most favorable integration scheme would place
the Brackish Marsh in series with the existing system (Figure
\ref{fig:tm-all-series}). This scheme would provide the greatest
level of treatment, and require a minimal re-distribution of flow.
The additional storage capacity provided by the Brackish Marsh would
act as a buffer during extreme high flows, giving plant operators
the flexibility required to respond to such events. In contrast, the
regime shown in Figure \ref{fig:tm-none} would provide no treatment
from the EMs and requires the greatest effort by the City to meet
discharge requirements using only the Ox Ponds and TMs upstream of
the Chlorine Contact Basin.

\begin{figure}[!ht]
\centering
\includegraphics{figs/tm-current.pdf}
\caption{Flow diagram illustrating the current hydraulic regime.}\label{fig:tm-current}
\end{figure}

\begin{figure}[!ht]
\centering
\includegraphics{figs/tm-all-series.pdf}
\caption{Flow diagram illustrating the full use of the
EMs.}\label{fig:tm-all-series}
\end{figure}

\begin{figure}[!ht]
\centering
\includegraphics{figs/tm-none.pdf}
\caption{Flow diagram illustrating the full removal of the
EMs.}\label{fig:tm-none}
\end{figure}


A third scenario would split the effluent from Hauser Marsh into two
streams. Roughly 50\% of the effluent would return to the Chlorine
Contact Basin and the other 50\% would be discharged to the Brackish
Marsh. The new discharge permit negotiations may also result in a
partial removal of the EMs (Figures \ref{fig:tm-no-hauser} and
\ref{fig:tm-allen-only}). Partial removal would provide new wetland
inventory for the NCRWQCB, and still provide a portion of the
original treatment and buffering capacity for the AWTF.

\begin{figure}[!ht]
    \centering
    \subfigure[Diagram of flow through Allen and Gearheart Marshes.\label{fig:tm-no-hauser}]{\includegraphics{figs/tm-no-hauser.pdf}}\\
    \subfigure[Diagram of flow through Allen Marsh.\label{fig:tm-allen-only}]{\includegraphics{figs/tm-allen-only.pdf}}
  \caption{Flow diagrams illustrating partial use of the EMs.}
  \label{fig:option34}
\end{figure}

\subsection{Fish Ponds}

The City plans to renovate a series of fish ponds adjacent to the
existing TMs. The fish ponds, as well as Ox Pond 3, will be
re-distributed as treatment marshes 5, 6, and 7. The additional storage and treatment capacity may
produce effluent of sufficient quality for direct chlorination and
discharge \citep{Gearheart2008} into Humboldt Bay. The renovation is particularly
important if the enhancement marshes are removed from the treatment system as ``Waters of the State''.


\section{Literature Review}\label{sec:litrev}

\subsection{Marshes}
Constructed wetlands are man-made marshes or swamps created to treat
municipal wastewater or stormwater runoff \citep{EPA2008b}.
Wetland treatment systems utilize natural
processes to improve water quality. These natural processes include
decomposition of organic matter by microbes, aerobic and anaerobic
decomposition, and filtration of pollutants and other suspended
solids from the wastewater \citep{EPA2004}. Pollutants are
transformed to less soluble forms as nutrients deposited in wetlands
\citep{EPA2004}.

There are two main types of wetlands: subsurface- and surface-flow.
Arcata utilizes surface flow, where water flows horizontally through
the system and is filtered by plant roots. Plants utilized in
wetlands include floating aquatic plants, submergent plants, and
persistent emergent plants such as bulrushes, spikerush, other
sedges, rushes, common reed, and cattails \citep{EPA2008b}.
Constructed wetlands are a cost-effective solution to treating
wastewater; they have low operating and maintenance costs, can
handle fluctuating water levels, reduce or eliminate odors, and are
aesthetically pleasing \citep{EPA2004}. Besides treating wastewater,
wetlands have many beneficial uses and are one of the most
biologically diverse and productive ecosystems \citep{EPA2004}.
Wetlands also provide extensive wildlife habitat, recreation space,
and other public use benefits \citep{EPA2004}.

\subsection{Wetland Models}

Numerous wetland models have been developed, predominantly as tools
for research in natural wetlands. Many of these models incorporate
both hydraulic and nutrient dynamics, though presently only
hydraulics are of concern. Two broad categories exist, lumped and
distributed flow models.

Distributed flow models attempt to resolve flow patterns within a
given wetland using the equations of momentum and
mass conservation. The advantage of such a model is the ability to
capture small-scale processes, e.g., short-circuiting and dead-zones
within a given wetland. Various authors have proposed mathematical
expressions to approximate fluid flow in wetlands and
frictional resistance due to vegetation and bottom roughness. The
most common forms are variations on Manning's equation  (a standard
formula used to simulate open-channel flow) and the diffusion
equation (most often used to simulate flow through porous media).

\cite{Guertin1987} developed a distributed model, PHIM, for wetlands
typical of those found in the Great Lakes region. PHIM is based on a
modified form of Manning's equation. Input to PHIM is limited to
climactic data (precipitation, humidity, etc.) and wetland
parameters (soil depth, vegetation thickness, etc.). The model was
applied to a watershed in northern Minnesota with short term flow
predictions within one standard deviation of the observed values.
\cite{Hammer1986} developed a similar distributed flow model, using
the Kadlec equation \citep{Kadlec1990} to approximate
vegetation-resistance to flow. The model was applied to a wetland in
Porter Ranch, Michigan, giving useful short-term predictions. A
WETLANDS package for the USGS groundwater model MODFLOW, was
developed for the South Florida Water Management District to better
understand the effect of nearby urbanization on wetlands above the
Biscayne Aquifer \citep{Montoya1998}. The package is capable of
simulating interaction between wetlands and underlying groundwater.
Simultaneous solution of overland and subsurface flow equations may
be computationally intensive. MIKE-SHE, developed by the Danish
Hydraulic Institute, is similar to MODFLOW and capable of modeling
wetland sloughs, groundwater interaction, and select hydraulic
control structures, e.g., weirs and sluice gates.
\cite{Thompson2004} tested the model extensively with data obtained
at the Elmley Marshes in the United Kingdom, and obtained good
agreement between observed and predicted flow rates.

Lumped flow models have also been developed for purposes of planning
and management. Such models are less computationally intensive, and
are preferred in scenarios where limited data is available regarding
the physical description of the system under investigation. Lumped flow
models attempt to resolve large scale flow processes, e.g., the net
movement of water into and out of a water body. The water balance is
expressed mathematically in terms of mass conservation (not momentum
conservation). Reservoir models, a particular class of lumped flow
models, discretize a watershed into a series of inter-connected
reservoirs.

Among the more well known lumped-flow packages are HEC-RAS and
PondPack. HEC-RAS, originally developed by the Army Corps of
Engineers for river analysis, has been proposed as a possible
wetland model for scenarios where sloughs and vegetated channels are
predominant \citep{HEC2008}. PondPack is a linear-reservoir model,
designed to simulate detention pond systems. PondPack is capable of
simulating various control structures, such as weirs and sluice-gates,
as well as climactic influences, e.g., precipitation and evaporation
\citep{Bentley2005}. \cite{Lee1999} developed the reservoir model
SETWET as a tool for managing pollution control in natural wetlands.
SETWET is capable of simulating both hydraulic- and
nutrient-dynamics.


\subsection{Control Structures}


\subsubsection{Weirs and Pipes}
Weirs, a type of control structure, are designed to reduce flow
rates and increase water depths, while providing an opportunity to
measure flow volume and velocity. Weirs can be used to aid in fish
passage along steep river sections, or to maintain a desired
upstream water depth. There are three main categories of weirs;
v-notch, sharp-crested rectangular, and broad-crested rectangular.
Sharp-crested weirs, the most common in wetland systems, are
constructed of metal plates and allow the water to fall cleanly away
from the plate. Weirs can have fixed elevations or variable heights.
Variable height weirs are vital to the hydraulic control of many
water systems, as they allow more control than fixed weirs.
\cite{White2008} details the mathematical equations governing flow
over weirs.


\subsubsection{Tide Gates}
The purpose of the tide gate, situated at the interface between the
Brackish Marsh and the bay, is twofold: (1) to regulate volumetric
flow into and out of the Brackish Marsh, thereby regulating salinity
in the marsh, and (2) to allow upstream fish passage via the pet
door in Figure \vref{fig:tidegate} \citep{Andre2008}. The tide gate
(patented as a ``Muted Tidal Regulator'') was designed and installed
by Nehalem Marine. A buoy on the marsh side is linked to a
mechanical arm which regulates the pet door. The tide gate behaves
as follows:

\begin{myen}
        \item {\it When not submerged on the bay side:} The circular door acts a counter-weight; the size of the opening is a function of the upstream head (the relationship can be approximated by a hydrostatic force balance).
    \item{\it When submerged on the bay side:} The size of the opening of the circular door is a function of both the upstream and downstream heads. The gate can only open towards the bay,
    and does so when the water level in the marsh is above the sea
    surface, and shuts when the sea surface is above the water level
    within the marsh. In this case, bay water can only enter the
    marsh through the pet door.
    \item{\it When marsh water level is high:} The pet door shuts mechanically when the water level in the marsh reaches a particular, adjustable, threshold, independent of the sea surface.
\end{myen}

The hydraulic model discussed in section \vref{sec:reservoir-model}
requires a rating curve at the downstream end of the tide gate. In
practice, because tide gate behavior varies by design, rating curves
are most often obtained by experimental methods \citep{Burt2001}. In
some cases, rating curves are determined via theoretical models. For
square flap gates, \cite{Litrico2005}, \cite{Belaud2008}, and
\cite{Burt2001} assume the gate behaves as an orifice when the angle
of opening is small. The size of the orifice is determined in each
case by a force balance. In the case of rectangular gates,
\cite{Belaud2008} assumes that flow around the vertical sides of the
gate can be approximated by rectangular weir equations, modified by
a factor related to the degree of submergence. Hydraulic analysis of
circular flap gates have also been performed, with limited success.
\cite{Burrows1997} used the equations of momentum-conservation to
develop flow equations calibrated with experimental data from
circular gates. The model was unable to predict low-flows associated
with small openings of the tide gate.

\begin{figure}[!htb]
\centering
\includegraphics[width=\textwidth]{figs/tidegate.pdf}
\caption{Diagram of the tide gate installed at the Brackish Marsh.}
\label{fig:tidegate}
\end{figure}


\subsection{Inflow Forecasting}

Influent, the flow rate of water into a system, is the most
important variable in modeling a wastewater treatment facility as it
directly effects the efficiency and capacity of each treatment
process. Wastewater influent is typically composed of a relatively
constant (if not predictable) human component, and a highly variable
non-human component which depends on season, precipitation and groundwater levels.
The primary contribution to the non-human component is rainfall
derived inflow and infiltration (RDII) \citep{Zhang2007}. The
magnitude of RDII is a function of precipitation and how ``leaky'' a
wastewater collection system is, i.e. how much storm water makes its
way into the sewer system. A system with high RDII is undesirable
because it requires a treatment facility be built with a higher
capacity than the human demand on the system.

The following criteria are desirable in a forecast model for the
inflow to the AWTF:
\begin{myen}
\item No real-time inflow input,
\item Incorporates historical precipitation and inflow data,
\item Driven by only precipitation,
\item Accounts for seasonal and/or smaller scale periodicity,
\item Flexible and robust handling of outliers,
\item Simple to generate forecasts.
\end{myen}
These criteria are based on the availability and quality of data or lack thereof.

Classification of a system's RDII involve measurement and analysis
of flow at the outlet of a subbasin and nearby rainfall. Traditional
analysis ``are ad hoc in nature giving little or no consideration to
their statistical validity''  \citep{Zhang2007}. Other more recent
approaches use autoregressive models \citep{Zhang2007} and
artificial neural net models \citep{El-Din2002}.  An autoregressive
model which involves inflow would require continual input of data
for maximum forecast accuracy which conflicts with criteria 1 above.
Artificial neural networks, such as the one used in
\cite{El-Din2002}, generally perform the best with large data sets
which is not available for the AWTF. There have also been attempts
at combined approaches using model weighting, though this approach
arguably conflicts with criteria 6 above \citep{Coulibaly2005}.

An alternative to the above methods is time series decomposition.
These methods decompose the available time series into periodic,
non-stationary trend and residual components.  The idea being that
after removing the periodic and trend components, the residuals of
the decomposed precipitation and inflow series would be more highly
correlated than the original series.  If the residuals were then
regressed, a forecast could be precipitation-driven without
requiring a real time inflow data input.  At first glance this
method satisfies all of the above criteria for a model (though
possibly not criteria 5).

The most well known time series decomposition method is X-11
\citep{Shiskin1967}.  This procedure has been drastically improved
upon in the more modern Seasonal-Trend Loess (STL) algorithm
\citep{Cleveland1990}.  In particular this method satisfies criteria
3-5.  \cite{Cleveland1990} showed that the STL method performed well
upon well known data sets.

\section{Methodology}

\subsection{Inflow Model}\label{sec:inflow-model}

The AWTF inflow is forecasted from rainfall through the STL
procedure outlined in \cite{Cleveland1990} for decomposing periodic,
non-stationary time series.  Along with being conceptually easy to
understand, this procedure has many advantages such as being able to
handle any size window of periodicity and missing data values
\citep{Mcleod1999}. A generic time series $Y_v$ can be written as
the sum of a seasonal component, $S_v$, a non-stationary trend
component, $T_v$, and a remainder, $R_v$, for all $v=1,2,...,n$ or

\[Y_v = S_v + T_v + R_v.\]

While the mathematical details of the procedure are beyond the scope
of this report and can be found in full detail in
\cite{Cleveland1990}, the following is a brief summary. The
procedure is iterative, consisting of two main loops of computation.
The inner loop, iterated $n_i$ times where $k=1,...,n_i$ is the
iteration number, consists of:
\begin{myen}
    \item {\it Detrending:} The detrended series $Y_v-T_v^{(k)}$ is calculated.  On the first iteration choose $T_v^{(1)}= 0$.
    \item {\it Cycle-Subseries Smoothing:} $S_v^{(k+1)}$ is calculated to guarantee smoothness between periods but not necessarily between adjacent time intervals.  This allows for jumps, slips and missing values to be handled robustly.
    \item {\it Deseasonalizing:}  The deseasonalized series $Y_v-S_v^{(k+1)}$ is calculated.
    \item {\it Trend Smoothing:}  The deseasonalized series is smoothed via loess, a locally weighted polynomial regression method (this method is also used in the computation of $S_v^{(k+1)}$).  Thus $T_v^{(k+1)}$ is obtained.
\end{myen}

The outer loop consists of the estimation of robustness weights
which are applied to the  trend smoothing in Step 4 of the inner
loop.  This process determines the degree to which outliers in $R_v
= Y_v - T_v - S_v$ are damped in the trend smoothing.  Finally, the
seasonal component is smoothed an additional time via loess to
obtain the final values of $S_v$, $T_v$ and $R_v$.

Due to the effects of groundwater storage, the inflow time series
$Y_{I,v}$ is expected to be a stronger function of the precipitation
over the past $m$ days than it is of the single day's precipitation.
Let $Y_{P(m),v}$ be a variant of the precipitation time series
$Y_{P,v}$, where
\[Y_{P(m),j}=\displaystyle\sum_{i=j-m}^jY_{P,i}.\]

Constructing the time series this way forces a restriction on $v$
from $m$ to $n$.

\[Y_{I,v} = S_{I,v} + T_{I,v} + R_{I,v}\label{idecomp}\]
and
\[Y_{P(m),v} = S_{P(m),v} + T_{P(m),v} + R_{P(m),v}\label{pdecomp}\]

Inflow residual is approximated as a linear function of the
precipitation residual such that

\[R_{I,v} = a + bR_{P,v}\label{linreg}\]
where $a$ and $b$ are estimated via linear regression.

In a forecast setting where real-time incorporation of inflow data
is not possible, some practical modification must be made:
\begin{myen}
    \item The trends in the inflow and precipitation series are assumed to be constant average values $\phi_I$ and $\phi_{P(m)}$
    \[\phi_I={\displaystyle\sum_{i=m}^n T_{I,i}\label{iave} \over n-m}\]
and
    \[\phi_{P(m)}={\displaystyle\sum_{i=m}^n T_{R(m),i}\label{pave}\over n-m}\]
    \item The seasonal component is assumed to be constant from year to year so that any year's component is representative of all the years in the record.  Thus the seasonal component is only a function of the day of the year $d$ and the starting day of the time series $d_o$ where $d,d_o\in\{1,2,...,365\}$ and
    \[d=mod\left[mod\left(v, 365\right)+d_o,365\right]\label{eqn:d}\]
so that
    \[S_{I,d} = S_{I,v} \,\,\,\,\,\,\,\,\,\forall v = 1,2,...,365\]
and
    \[S_{P(m),d} = S_{P(m),v} \,\,\,\,\,\,\,\,\,\forall v = 1,2,...,365.\]
Note that $mod$ is the remainder function.
\end{myen}

Given precipitation amounts for the last $m$ days, and the current
day of the year, $d$, the entire forecast procedure follows:

\begin{myen}
    \item Construct $Y_{P(m),v}$ from the original time series $Y_{P,v}$.
    \item Decompose $Y_{I,v}$ and $Y_{P(m),v}$ into the components in Equations \ref{idecomp} and \ref{pdecomp}.
    \item Calculate $\phi_I$ and $\phi_{R(m)}$ from Equations \ref{iave} and \ref{pave}
    \item Estimate $a$ and $b$ from Equation \ref{linreg}.
    \item Calculate $\mathcal{P}$ as the sum of the last $m-1$ days of observed precipitation plus the current day's precipitation forecast.
    \item Calculate $d$ from Equation \ref{eqn:d}.
    \item Obtain a forecast of the inflow $\mathcal{I}$ as
        \[\mathcal{I} = \left(\mathcal{P}+S_{P(m),d}+\phi_{P(m)}\right)b+a+S_{I,d}+\phi_{I}.\label{eqn:forecast}\]
\end{myen}
    Notice that every value on the right hand side of Equation \vref{eqn:forecast} is simply a scalar and thus $\mathcal{I}$ is a scalar as well. Steps 1 - 4 consist of model calibration and are only carried out once.  Steps 5 - 7 are repeated daily to obtain a forecast as shown in Figure \vref{fig:inflow-model-schematic}.

\begin{figure}[htbp] %  figure placement: here, top, bottom, or page
   \centering
   \includegraphics{figs/inflow-model-schematic.pdf}
   %\subfigure{\includegraphics{figs/stl-schematic.pdf}}
   \caption{Schematic of the forecasting procedure as carried out in practice.}
   \label{fig:inflow-model-schematic}
\end{figure}


\subsection{Pond and Wetland Modeling}

\subsubsection{Weirs and Pipes}
\cite{King1963} present the most widely accepted equations of flow
over submerged and non-submerged weirs (Equations
\ref{submerged_weir} and \vref{nonsubmerged_weir}, respectively),
assuming negligible approach velocities in both cases. The same
authors present equations for frictional losses through pipes and
gates (Equations \ref{pipes} and \vref{gates}, respectively),
assuming turbulent flow in both cases.

\[ Q=(2g)^{\frac{1}{2}}L\left[\frac{2}{3}(H-D)^{\frac{2}{3}}+D(H-D)^{\frac{1}{2}}\right] \label{submerged_weir}\]

\[ Q=\frac{2}{3}(2g)^{\frac{1}{2}}LH^{\frac{3}{2}} \label{nonsubmerged_weir}\]

\[h_p = \frac{8flQ^2}{d^5\pi^2g}\label{pipes}\]

\[h_g = K_g\frac{v^2}{2g}\label{gates}\]

Above, $Q$ is the volumetric flow rate, $v$ is the velocity of flow,
$w$ is the width of a weir, $H$ and $D$ are respectively the
upstream and downstream heads above the crest of a weir, $g$ is the
acceleration due to gravity, $h_p$ and $h_g$ are frictional head
losses through a pipe and gate, $d$ and $l$ are respectively the
pipe-diameter and pipe-length, $K_g$ is a dimensionless coefficient
of head-loss through a gate, and $f$ is a dimensionless friction
factor - roughly 0.01 for turbulent flow through PVC pipes similar
to those at the constructed wetlands \citep{White2008}.

\subsubsection{Linear-Reservoir Model}\label{sec:reservoir-model}
The linear-reservoir model employs the following assumptions: (1)
the water surface of each reservoir remains level at all times,
i.e., no prism storage occurs, (2) the stage discharge relationship
exhibits no hysteresis, i.e., the relationship is identical during
filling and emptying of the reservoir, (3) the stage of each
reservoir is essentially constant during some small time interval
$\Delta t$, such that the discharge is also constant during the same
interval. The mathematical model is an expression of mass
conservation (Equation \vref{mass_balance_1}), where $S$ is the
storage volume, $Q_{i}$ is the volumetric inflow during time
$\Delta t$, and $Q_{o}$ is the volumetric outflow

\[\frac{\Delta S}{\Delta t} = Q_{in}-Q_{o}.\label{mass_balance_1}\]

If the surface area of the reservoir is independent of depth, the
equation can be expressed in terms of the surface elevation $H$, and
surface area $A$

\[A\frac{\Delta H}{\Delta t} = Q_{i}-Q_{o}(H)\label{mass_balance_2}.\]

$Q_{o}(H)$ is now the stage-discharge relationship, which depends
on the parameters of the outfall structure.

Calculating the flow from one reservoir to another through a control
structure such as that in Figure \vref{fig:tidegate} requires
apriori knowledge of frictional losses. However, calculation of the
frictional losses requires apriori knowledge of the magnitude of
flow. We use the iterative procedure described by \cite{Chow1988} to
solve this problem (Figure \vref{fig:flow-model-schematic}). The
hydraulic behavior of the system is controlled primarily by the
elevation of the weirs, which are seldom adjusted in practice. As
such, the corresponding parameters of the model are held constant
during any given simulation. Equation \vref{mass_balance_2} is
numerically integrated over the duration of simulation using a variable-timestep
Runge-Kutta algorithm, described in mathematical detail by
\cite{Chow1988}. The length of each timestep is adjusted according
to the change in water surface elevations during the previous timestep. A diagram of
the entire simulation process is shown in Figure \vref{fig:flow-model-schematic}.

\begin{figure}[!h] %  figure placement: here, top, bottom, or page
   \centering
   \includegraphics{figs/flow-model-schematic.pdf}
   \caption{Schematic of the iterative algorithm for calculating pond depths over time.}
   \label{fig:flow-model-schematic}
\end{figure}


\section{Application}

\subsection{Inflow Model and Data Inputs}
Three precipitation data sets are available for analysis: one
stationed at the NOAA weather station on Woodley Island near Eureka,
one stationed at the Redwood Sciences Laboratory in the Arcata
Community Forest, and one stationed at a residence in Sunny Brae
\citep{Ruegg2008}. All data sets provided adequate time series
duration for proper analysis and correlation.  Correlations between
plant inflow and the Redwood Sciences data set was unsatisfactory
but both of the other rainfall data sets were equally strong. The
NWS data set is utilized in this project as forecasted data is
readily available.

\subsection{Pond and Wetland Model and Data Inputs}

Three forms of data are available for use within the hydraulic
model: (1) inflow (both precipitation and municipal influent), (2)
predicted sea-surface elevations, and (3) physical properties of the
system, e.g., weir elevations, pond areas, etc. Predicted
precipitation is obtained daily from the National Weather Service \footnote{http://www.wrh.noaa.gov/forecast/wxtables/};
this data is used to drive the municipal inflow
prediction model described in Section \ref{sec:inflow-model}.

Predicted sea surface elevations downstream of the tide gate are
provided by a local branch of the National Oceanic and Atmospheric
Administration (NOAA). NOAA has implemented a regional circulation
model, ADCIRC, that predicts tidally-forced and wind-driven seas
throughout Humboldt Bay. ADCIRC (an ADvanced CIRCulation model
supported by the Army Corps of Engineers) is driven by local tidal
harmonics, retrieved from the WaveWatch III Eastern North-Pacific
database \citep{Mark2004}, model-derived winds from the Global
Forecast System (GFS40) and the North American Mesoscale model
(NAM12); all of which are supported by the National Weather Service
(NWS). Wetland parameters have been obtained from direct
measurement, recent GIS data \citep{Kang2008}, planning documents
\citep{CH2MHill}, and personal communication with treatment plant
operators \citep{Clinton2008,lust2008}. To calibrate the hydraulic
model, daily records were obtained from the AWTF staff  including
weir elevations, pumping schedules, and water surface elevations of
the Ox Ponds, and EMs.

Hydraulic behavior of the constructed wetlands is complex. While the
Ox Ponds are generally free of obstruction, the TMs and EMs contain
a layer of dense vegetation. Bathymetry of the system is irregular
and changes with time due to varying volumes of sludge and plant litter.
Bottom depths are difficult to measure and vary over lateral
distances of less than 10 meters. Flow paths are affected not only
by the local variation just described, but also by the location and
elevation of weirs and other control structures. For instance,
slight differences in the elevation of adjacent weirs (on the order
of centimeters) can affect the size of dead-volumes in a given
pond or marsh. Such complexity precludes the development of an
accurate distributed flow model of the wetlands within
the time frame of this study. More importantly, a distributed flow
model would be inappropriate for the desired resolution of predicted
flows (in both time and space).

Although the system is complex, several factors exist which make the
task of modeling more tractable. The time scale during which
complex/localized flow processes occur is small in comparison to the
hydraulic residence times of each wetland body. As a result, water
surfaces in the wetlands are nearly horizontal during all but the
most extreme conditions. In addition, changes in water surface
elevations occur on the time scale of hours to days, allowing for
the assumption that depths are constant over the time scale of
minutes. In short, the hydraulic behavior of the wetlands is less
complex over large time scales. Because this is the desired
resolution of prediction, and because of the nearly-horizontal water
surfaces, a linear-reservoir (level-pool) model is appropriate.

The mathematical development of the linear-reservoir model was
discussed in section \ref{sec:reservoir-model}. Here, we describe only the
parameters of the system. The wetlands are described in the model as
a series of interconnected linear-reservoirs, each have multiple
inlets and outlets (Figure \ref{fig:schematic-tm} and \ref{fig:schematic-em},
Appendix A). Each component of the
hydraulic control system is represented by a prototypical structure with various
parameters (Figure \vref{fig:prototype}).
\begin{figure}[!htb]
\centering
\includegraphics[width=\textwidth]{figs/prototype.pdf}
\caption{Prototypical control structure with labeled parameters.}
\label{fig:prototype}
\end{figure}
For example, to represent a gated pipe the structure would have the
following parameters: $l_1$=20ft., $f_1$=0.01, $g_1$=0.5, and the
remaining parameters would be set to zero.

The tide gate (Figure \vref{fig:tidegate}), which connects the Brackish Marsh
to the bay, is modeled via a rating-curve provided by the user. The rating
curve is discrete, and specifies the volumetric flow corresponding to
paired data of upstream (Brackish Marsh) and downstream (Humboldt Bay) hydraulic head.
Due to a lack of physical data required to develop a rating curve at the tide gate, flow
through the gate is modeled as follows:
\begin{myen}
        \item{\it When flow is from the marsh into the bay:} The gate behaves as open pipe with a large friction factor.
        \item{\it When flow is from the bay into the marsh, and the pet-door is not submerged:} The gate behaves as a sharp-crested weir having a width equal to the width of the pet door, and elevation equal to the elevation of the lower edge of the pet door.
        \item{\it When flow is from the bay into the marsh, and the pet-door is fully submerged:} The gate behaves as an orifice having an area equal to the area of the pet-door.
\end{myen}



The linear-reservoir model was implemented in the computer language
R \citep{R-manual}. Calibration of the model was accomplished by varying the
frictional losses and pipe lengths at each control structure to
minimize the difference between observed and model-derived water
surface elevations. A continuous record spanning the months of June
through August, 2007, was chosen for calibration. Relatively few
precipitation events occurred during this period, and only minor
adjustments to weir heights and pumping schedules were made. This
particular data set was chosen to avoid discontinuities in observed
water surface elevations that occur as a result of rapid changes not
captured by the resolution of daily records. Verification of the
calibrated model was performed with data from December of 2005
during which several large precipitation events occurred causing instantaneous plant inflows greater than 8 mgd.


\section{Results \& Discussion}
\subsection{Inflow Model}
The strongest correlation between inflow and rainfall was observed
when the past 4 days of rainfall were added.  Figure
\vref{fig:collect} shows how the correlation changes as a function
of the number of previous days which the
rainfall was summed over.  This value of 4 days is related to the
average amount of time local aquifers need to become saturated. A time series plot of treatment plant inflow and the 4-day sum of precipitation values is shown in Figure \vref{fig:ts}.


\begin{figure}[!htbp] %  figure placement: here, top, bottom, or page
   \centering
   \includegraphics[height=\textwidth,angle=-90]{figs/collect.pdf}
   \caption{Correlation between plant inflow and rainfall as a function of the number of days over which the rainfall is summed to create a new time series.}
   \label{fig:collect}
\end{figure}

\begin{figure}[!htbp] %  figure placement: here, top, bottom, or page
   \centering
   \includegraphics[height=\textwidth,angle=-90]{figs/inflow-ts.pdf}
   \caption{Treatment Plant Inflow (in black) and Eureka Precipitation (in blue) plotted on the same axis.}
   \label{fig:ts}
\end{figure}

Figure \vref{fig:inflow-pred} shows a sample of the hindcasted plant
inflows (with 95\% confidence intervals) and observed flows. The
standard error using the STL algorithm was 0.6642.  The model
residuals were not precisely normally distributed, being slightly
skewed to the right. The slight skewness caused 63\% of the values
outside of the confidence interval to be larger than the upper
limit. In total, 7.474\% of the observations fell outside of the
95\% confidence interval where 5\% was expected, reflecting the
model's inability to capture the highest flow events.  A major cause
of this could related to the difficulty of obtaining accurate
measurements of high flow events.

The model calibration and forecast have been performed in the
programming language R \citep{R-manual}. Forecasted inflows are updated daily and
are available
online\footnote{\href{http://firehole.humboldt.edu/\%7Eacvmarsh/inflow/inflow}{http://firehole.humboldt.edu/\%7Eacvmarsh/inflow/inflow}}.


\begin{figure}[!htbp] %  figure placement: here, top, bottom, or page
   \centering
   \includegraphics[scale=0.8,angle=-90]{figs/inflow-pred.pdf}
   \caption{A portion of observed (thick black solid line) and hindcasted (thin solid red line) plant inflows.  95\% confidence intervals are shown as dotted lines. }
   \label{fig:inflow-pred}
\end{figure}

\subsection{Pond and Wetland Model}

The calibrated hydraulic model was able to hindcast water surface
elevations in the Ox Ponds and EMs to within 0.1 ft. of the observed
values during the Summer of 2007; hindcasted elevations during the
month of June are shown in Figure \vref{hindcast-summer-head}.
During the same period, model-derived discharge from the Chlorine
Contact Basin followed the observed values to within 0.5 mgd. Sharp
peaks in the observed bay discharge are not captured by the model,
rather, hindcasted values lie closer to the running average of the
observed values (Figure \vref{hindcast-summer-flow}).

\begin{figure}[!htb]
    \centering
    \subfigure[Hindcasted water surface elevations in the Ox Ponds during June, 2007.\label{hindcast-summer-head}]{\includegraphics[height=\textwidth,angle=270]{figs/summer2007.pdf}}
    \subfigure[Hindcasted bay discharges during June, 2007.\label{hindcast-summer-flow}]{\includegraphics[height=\textwidth,angle=270]{figs/summer2007-2.pdf}}
  \caption{Calibrated dry weather model results.}
  \label{fig:hindcast-summer}
\end{figure}

The calibrated model was verified with data from December 2005. Two
consecutive rainfall events occurred during the first twelve days of
the month, causing peak inflows of 5.5 and 7 mgd; the magnitude,
duration, and proximity of these events are typical of the wet
season in Arcata. Model results during this period are shown in
Figure \vref{fig:hindcast-winter}. Water surface elevations were
hindcasted to within 0.2 ft. of the observed values, while bay
discharge was hindcasted to within 1 mgd. As shown, the model tends
to over predict the elevation of Ox Pond 3 during high flows. Small
oscillations in the model-derived discharge are due to the pumping
schedule governing the return flow from Hauser Marsh to the Chlorine
Contact Basin.

\begin{figure}[!htb]
    \centering
    \subfigure[Hindcasted water surface elevations in the Ox Ponds during December, 2005.\label{hindcast-winter-head}]{\includegraphics[height=\textwidth,angle=270]{figs/Winter2005-2.pdf}}
    \subfigure[Hindcasted bay discharges during December, 2005.\label{hindcast-winter-flow}]{\includegraphics[height=\textwidth,angle=270]{figs/Winter2005.pdf}}
  \caption{Calibrated wet weather model results.}
  \label{fig:hindcast-winter}
\end{figure}

In-series Brackish Marsh integration scenarios were simulated for
December of 2005--2007 using observed plant inflows and hindcasted
sea levels; model results from December 2005 are shown in Figure
\vref{fig:in-series-winter}). During these simulations, all
chlorinated effluent was assumed to be discharged either to Allen
Marsh or directly to the Brackish Marsh, as shown in Figure
\vref{fig:tm-all-series}. Currently, the installed pumping capacity
at the downstream end of Hauser Marsh is 4.5 mgd. To avoid potential
overflow, the flowrate from the Chlorine Contact Basin to Allen
Marsh was limited to 4.5 mgd, and excess flow was routed directly to
the Brackish Marsh. The desired flowrates were achieved by adjusting
the V-notch weir in the Chlorine Contact Basin once daily; sharp
changes in the flow from the Chlorine Contact Basin to Allen Marsh
shown in Figure \ref{fig:in-series-winter} are due to instantaneous
adjustments of the V-notch weir. In the extreme case (sustained flow
at 4.5 mgd through the EMs) the model predicts over-topping of
Gearheart and Hauser Marshes given their present weir elevations.
However, sustained flow at 4.5 mgd was feasible when the adjustable
weir located at the south-east end of Gearheart Marsh was lowered by
4--6 in. from the present height. Given the weir adjustment, the
resulting maximum water surface elevations correspond to 4--5 in. of
freeboard in each of the EMs. The weir adjustment was assumed during
each of the integration simulations.

\begin{figure}[!htb]
\centering
\includegraphics[width=\textwidth,angle=270]{figs/in-series-winter.pdf}
\caption{Model-derived flows and water surfaces after integration of
the Brackish Marsh in-series with the EMs. Sharp changes in the flow
from the Chlorine Contact Basin into Allen Marsh are due to
`'instantaneous' adjustments of the V-notch weir in the Chlorine
Contact Basin.} \label{fig:in-series-winter}
\end{figure}

Based on the analysis, integration of the Brackish Marsh in series
with the existing tertiary treatment system is feasible in terms of
capacity. Assuming high flows are appropriately routed upstream of
the Chlorine Contact Basin, and flows in excess of 4.5 mgd are
routed from the Chlorine Contact Basin directly into the Brackish
Marsh, the capacities of existing control structures in the EMs are
sufficient to prevent over-topping. In each of the simulations, the
net flow was from the Brackish Marsh to the bay; however, the
direction of instantaneous flow oscillates with the tidal cycle.
During wet weather scenarios at high tide, the sea level generally
rises 1--2 ft. above the highest level in the Brackish Marsh (high
enough to submerge the pet door). Between low and high tide, the
water surface elevation of the Brackish Marsh oscillates at an
amplitude of 1 to 3 in. The average theoretical residence times
(Equation \ref{eq:residence}) corresponding to the simulations are
shown in Figure \ref{fig:residence}. Residence times are important
from a water quality perspective; longer residence times are
associated with higher nutrient removal and a higher quality
effluent. A water quality model is necessary to evaluate the effect
of residence time on the effluent quality. Further, a distributed
flow model (as discussed in section \ref{sec:litrev}) is necessary
to evaluate the possibility of short-circuits associated with high
flows through the EMs.

\[ \mbox{Residence Time} = \mbox{Volume} \div \mbox{Flow} \label{eq:residence} \]

\begin{figure}[!htb]
\centering
\includegraphics[height=\textwidth,angle=270]{figs/res-bargraph.pdf}
\caption{Average theoretical residence times, present and post brackish marsh integration (`in-series' scenario).}
\label{fig:residence}
\end{figure}


While in-series integration of the Brackish Marsh is favorable in
terms of treatment, the EMs may be removed from the treatment train
as per negotiations with the NCRWQB. To simulate historical events
given this scenario, all chlorinated effluent was assumed to be
discharged directly to the Brackish Marsh, as shown in Figure
\vref{fig:tm-none}. Results indicate that direct discharge into the
Brackish Marsh is feasible in terms of flow (Figures
\vref{fig:direct-integration-summer} and
\vref{fig:direct-integration-winter}). In these scenarios, water
levels in the Brackish Marsh are more sensitive to changes in flow
from the Chlorine Contact Basin. Previously, the EMs had the effect
of buffering peak flows from the Chlorine Contact Basin, thereby
smoothing the flow to the Brackish Marsh. During the dry season, the
water level in the Brackish Marsh is expected to oscillate between
2--3 ft. above MSL. During the wet-season, the water level would
oscillate between 3--4 ft. above MSL, still below the point of
overtopping into Gearheart Marsh (the lowest point on the dividing
berm is 6.36 ft. above MSL). As in the previous scenario, the
theoretical residence time in the Brackish Marsh is roughly 5 days
during the dry season, and 6 days during the wet season.

\begin{figure}[!htb]
\centering
\includegraphics[scale=1.05,angle=270]{figs/direct-integration-summer.pdf}
\caption{Model-derived flows and water surfaces after integration of
the Brackish Marsh directly downstream of the Chlorine Contact Basin
(summer scenario).} \label{fig:direct-integration-summer}
\end{figure}

\begin{figure}[!htb]
\centering
\includegraphics[scale=1.05,angle=270]{figs/direct-integration-winter.pdf}
\caption{Model-derived flows and water surfaces after integration of
the Brackish Marsh directly downstream of the Chlorine Contact Basin
(winter scenario).} \label{fig:direct-integration-winter}
\end{figure}

The accuracy of the inflow and hydraulic models, and the resulting
conclusions regarding the feasibility of Brackish Marsh integration
scenarios, are heavily dependant on the historical data used for
calibration. Data used to calibrate the linear-reservoir model spans
only the Summer of 2007, whereas calibration with wet weather values
might improve the results. To improve the accuracy of the
model-derived flowrate, rating curves might be developed via
experimental methods for each control structure, including the tide
gate located at the interface between the Brackish Marsh and the
Bay. Feasibility is discussed in this paper only in terms of flow,
i.e., whether water can be routed through the system while
maintaining appropriate water surface elevations. Ultimately, the
feasibility of integrating the Brackish Marsh will be judged
according to water quality standards in addition to flowrates.

\newpage
\newpage
\subsection{Simulation Package for AWTF Operators}

The hydraulic model is meant to serve as an operational tool at the
AWTF. A web-based model interface was created to give quick, easy
access to forecasted data, and to assist in investigating the
effects of adjusting physical parameters of the system (Figure
\vref{fig:screenshot}). The webpage allows treatment plant operators
to specify individual weir elevations, pump schedules, plant inflow,
initial conditions, and precipitation/evaporation. Once the
information is submitted, a model run is triggered and results are
displayed in graphical form (Figure \vref{fig:sample-bargraph}), and
as a colored map (Figure \vref{fig:screenshot}). These visual aids
allow operators to quickly assess the criticality of wetland levels.

\begin{figure}[!htb]
\centering
\includegraphics[scale=.75]{figs/Webpage_Screenshot_Page_1.pdf}
\caption{Screenshot of the interactive webpage for remote model
execution by AWTF operators. Blue represents low pond levels, green
represents nominal levels, and red represents high levels.}
\label{fig:screenshot}
\end{figure}

The webpage offers treatment plant operators two modes of model use:
(1) operational mode, and (2) analysis mode. In operational mode,
model results and system settings from the previous day are loaded
as the initial conditions for the current day. Every morning model
derived inflows are automatically loaded based upon National Weather
Service forecasted QPF (quantitative precipitation forecasts). Users
have the option to manually adjust system parameters if necessary.
Daily use of the webpage in this mode will allow for quick and easy
use as parameters are carried through from the previous day. In
analysis mode, the user can perform "what-if" scenarios regarding
the system without making potentially hazardous physical
modifications. When a high inflow event is predicted, this mode may
be utilized to determine system response to changes in physical
parameters, i.e., weir heights and pumping schedules.

\begin{figure}[!htb]
\centering
\includegraphics[width=.5\textwidth,angle=270]{figs/sample-bargraph.pdf}
\caption{Graphical results displayed on the model webpage.}
\label{fig:sample-bargraph}
\end{figure}

\begin{figure}[!htb]
\centering
\includegraphics[width=.5\textwidth,angle=270]{figs/rating_curve.pdf}
\caption{Sample rating curve for the set of weirs located between Ox
Pond 2 and either TM 1 or 2. The value associated with each contour
line represents the absolute elevation of the weir crest.}
\label{fig:rating-curve}
\end{figure}

Model-derived rating curves for each control structure are available
on the webpage (Figure \vref{fig:rating-curve}). The rating curves
may be utilized in operational decision making. For example: (1) the
measured water surface elevation in Ox Pond 2 is 5 ft. above MSL,
(2) in order to move water into TM 1 at a rate of 2 mgd, both weirs
leading from Ox Pond 2 into TM 1 may be adjusted to an elevation of
3 in. above the water surface in Ox Pond 2, (3) from Figure
\ref{fig:rating-curve}, this adjustment allows roughly 1 mgd of flow
across each weir, for a total of 2 mgd.



\newpage
\newpage
\section{Conclusion and Recommendations}

A simulation model was developed to forecast and manage the hydraulic
behavior of the constructed wetlands at the Arcata Wastewater
Treatment Facility. In addition, a statistical model was developed
to forecast treatment plant inflows given observed and forecasted
rainfall. Both models were calibrated and verified with historical
data. Finally, an intuitive web interface was developed to perform
simulations and display model results.

The hydraulic model was used to investigate the feasibility of
integrating a Brackish Marsh with the existing treatment system
while maintaining a single point of discharge. Our results indicate
that the integration scenario is feasible given the following
adjustments: (1) Flows less than 4.5 mgd would be routed from the
Chlorine Contact Basin to Allen Marsh, (2) flows in excess of 4.5
mgd would be routed from the Chlorine Contact Basin directly to the
Brackish Marsh, (3) the adjustable weir located at the south-east
end of Gearheart Marsh would be lowered by 4--6 inches from the
present height. Further study is required to assess whether the
scenario meets water quality constraints.

Future work may improve upon the accuracy of our results: (1) the
inflow model may account for soil moisture content and the position
of the groundwater table, (2) flow through the tidegate may be
predicted more accurately by developing a rating curve via
experimental methods, (3) staff-gauges may be installed where
necessary to facilitate the measurement of both water surface
elevations and weir heights for model input.

\clearpage
\addcontentsline{toc}{section}{References}
\bibliography{references}

\clearpage \addcontentsline{toc}{section}{Appendix A - AWTF System Specifications}
\section*{Appendix A  - AWTF System Specifications}\label{sec:appendix-connections}

\begin{figure}[!htbp]
\centering
\includegraphics[width=\textwidth]{figs/schematic-tm.pdf}
\caption{Aerial schematic of the constructed Treatment Marshes, including
control structures (numbers correspond to numbers in Tables \ref{tab:weir-elev} and \ref{tab:pump-capacity}).} \label{fig:schematic-tm}
\end{figure}

\begin{figure}[!htbp]
\centering
\includegraphics[width=\textwidth]{figs/schematic-em.pdf}
\caption{Aerial schematic of the constructed Enhancement Marshes, including
control structures (numbers correspond to numbers in Tables \ref{tab:weir-elev} and \ref{tab:pump-capacity}).} \label{fig:schematic-em}
\end{figure}

\begin{table}[!htbp]
   \centering
   \caption{Pond and Marsh General Information.}\label{tab:general-info}
   \begin{tabular}{@{} cccccc @{}}
      \toprule
                     & Surface        & Min/Ave/Max  & Detention   & Bottom           &  Berm \\
                     &  Area (ft.$^2$) & Depth (ft.)  & Time (days) & Elevation (ft.)  &  Area \\
      \midrule
      Ox. Pond 1     & 1029059        &  5.1/5.25/6  & 35          & 1.97             & 93534 \\
      Ox. Pond 2     & 776105         &  5/5.15/5.9  & 35          & 1.31             & 71292 \\
      Ox. Pond 3     & 161244         &  5/5.15/5.9  & 5           & 0.66             & 26670 \\
      TM 1           & 53560          &  --/5/--     & 1.9         & --               & 19280 \\
      TM 2           & 79807          &  --/2/--     & 1.9         & --               & 20072 \\
      TM 3           & 80111          &  --/2/--     & 1.9         & --               & 26670 \\
      TM 4           & 53560          &  --/4.6/--   & --          & --               &  --   \\
      Contact Basin  & 2 $\times$ 2084 &  --/--/--   & 0.02        & 1.25             &  --   \\
      EM Allen       & 471875         &  0/1.5/6     & 9           & 0                & 160397\\
      EM Gearheart   & 322845         &  0/1.5/5     & 9           & 0.625            & 72442 \\
      EM Hauser      & 45062          &  0/1.5/5.5   & 9           & -1.88            & 189721\\
      Brackish Marsh & 569500         &  --/--/--    & --          & 1                & 115911\\
      \bottomrule
   \end{tabular}
\end{table}

\begin{table}[!htbp]
   \centering
   \caption{Weir Box and Crest elevations.}\label{tab:weir-elev}
   \begin{tabular}{@{} ccc @{}}
      \toprule
         Weir Number & Box Top & Weir Crest \\
          & Elevation (ft.) & Elevation (ft.) \\
      \midrule
      1   & 7.95   & 4.93 \\
      2   & 7.82   & 5.38 \\
      3   & 7.65   & 5.27 \\
      4   & 7.61   & 5.22 \\
      5   & 7.02   & 5.22 \\
      6   & 7.01   & 6.74 \\
      7   & 7.07   &  --  \\
      8   & 7.04   &  --  \\
      9  & 6.94   & 5.25 \\
      10  & 3.94   & 2.67 \\
      11  & 4.16   & 2.64 \\
      12  & 4.27   & 2.69 \\
      13  & 4.46   & 2.69 \\
      14  & 3.75   & 2.68 \\
      15  & 3.65   & 2.71 \\
      16  & 3.88   & 2.70 \\
      17  & 3.88   & 2.66 \\
      18  & 2.80   &  --  \\
      19  & 7.61   &  --  \\
      20  & --     &  --  \\
      21  & 7.74   &  --  \\
      21  & 7.20   &  --  \\
      22  & 7.78   &  --  \\
      23  & V-notch   &  --  \\
      24  & V-notch   &  --  \\
      25  & 6.95   &  --  \\
      26  & 7.20   &  --  \\
      27  & 7.78   &  --  \\
      28  & 7.70   &  --  \\
      29  & 7.61   &  --  \\
      30  & 7.26   &  --  \\
      \bottomrule
   \end{tabular}
\end{table}

\begin{table}[!htbp]
   \centering
   \caption{Pump Capacities.}\label{tab:pump-capacity}
   \begin{tabular}{@{} cccc @{}}
      \toprule
      Pump Station & Stage 1        & Stage 2        & Stage 3        \\
      Number       & Capacity (mgd) & Capacity (mgd) & Capacity (mgd) \\
      \midrule
      1            & 0--10          & --             & --  \\
      2            & 1.67           & --             & --  \\
      3            & 2              & 4              & --  \\
      4            & 1.5            & 2.4            & --  \\
      5            & 4.2            & 5.8            & --  \\
      6            & 1.2            & 2.3            & 2.9 \\
      7            & 1.5            & 3.0            & 4.5 \\
      \bottomrule
   \end{tabular}
\end{table}



\end{document}



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%
% Document Ends Here
%
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
